package com.tarena.lbs.activity.consumer;



import com.rabbitmq.client.Channel;
import com.rabbitmq.client.Connection;
import com.rabbitmq.client.ConnectionFactory;
import com.tarena.lbs.common.event.LocationEvent;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.io.IOException;
import java.util.concurrent.TimeoutException;


/**
 * 用户位置信息消费者
 * 消费用户位置信息 实现自动营销
 */
@Slf4j
@Component
public class StoreLocationConsumer {
    /*private Channel channel = null;

    public void init() throws IOException, TimeoutException {
        ConnectionFactory factory = new ConnectionFactory();
        factory.setHost("localhost");
        factory.setPort(5672);
        factory.setUsername("guest");
        factory.setPassword("guest");
        factory.setVirtualHost("/");
        Connection connection = factory.newConnection();
    }*/


    public void consume(LocationEvent event){

    }
}
